<template>
  <el-radio-group v-model="selected" size="mini" @change="onchange">
    <el-radio :label="1">大班</el-radio>
    <el-radio :label="2">中班</el-radio>
    <el-radio :label="3">小班</el-radio>
  </el-radio-group>
</template>

<script>
export default {
  props: {
    value: {
      type: Number,
      default: 0,
    },
  },

  watch: {
    value() {
      this.selected = this.value;
    },
  },

  data() {
    return {
      selected: this.value,
    };
  },

  methods: {
    onchange(value) {
      this.$emit("input", value);
    },
  },
};
</script>

<style>
</style>